package com.cy.pj.sys.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;

/**
 * 处理页面请求
 */
@Controller
@RequestMapping("/")
public class PageController {

    @GetMapping("doIndexUI")
    public String doIndexUI(){
        return "starter";
    }
    /*
    @RequestMapping("log/log_list")
    public String doLogUI() {
        return "sys/log_list";
    }
    @RequestMapping("menu/menu_list")
    public String doMenuUI() {
        return "sys/menu_list";
    }
    */
    //以上两个方法的映射 rest风格
    @RequestMapping("{module}/{moduleUI}")
    public String doModuleUI(@PathVariable String moduleUI) {
        return "sys/"+moduleUI;
    }

    @RequestMapping("doPageUI")
    public String doPageUI() {
        return "common/page";
    }
}



